package cn.kai.ums.model;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import lombok.Data;

/**
 * 
 * @TableName ums_class_course_teach
 */
@TableName(value ="ums_class_course_teach")
@Data
public class UmsClassCourseTeach implements Serializable {
    /**
     * 必修课上课自增id
     */
    @TableId(type = IdType.AUTO)
    private Integer classCourseTeachId;

    /**
     * 课程编号，由专业编号（4位）+学期信息（6位）+数字（2位）组成
     */
    private String classCourseTeachNo;

    /**
     * 班级编号
     */
    private String classCourseTeachClassNo;

    /**
     * 教师编号
     */
    private String classCourseTeacherNo;

    /**
     * 上课的教室
     */
    private String classCourseTeachClassRoom;

    /**
     * 0-5表示周一到周五
     */
    private Integer classCourseTeachDay;

    /**
     * 上课时间(13:00-14:40)
     */
    private String classCourseTeachTime;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        UmsClassCourseTeach other = (UmsClassCourseTeach) that;
        return (this.getClassCourseTeachId() == null ? other.getClassCourseTeachId() == null : this.getClassCourseTeachId().equals(other.getClassCourseTeachId()))
            && (this.getClassCourseTeachNo() == null ? other.getClassCourseTeachNo() == null : this.getClassCourseTeachNo().equals(other.getClassCourseTeachNo()))
            && (this.getClassCourseTeachClassNo() == null ? other.getClassCourseTeachClassNo() == null : this.getClassCourseTeachClassNo().equals(other.getClassCourseTeachClassNo()))
            && (this.getClassCourseTeacherNo() == null ? other.getClassCourseTeacherNo() == null : this.getClassCourseTeacherNo().equals(other.getClassCourseTeacherNo()))
            && (this.getClassCourseTeachClassRoom() == null ? other.getClassCourseTeachClassRoom() == null : this.getClassCourseTeachClassRoom().equals(other.getClassCourseTeachClassRoom()))
            && (this.getClassCourseTeachDay() == null ? other.getClassCourseTeachDay() == null : this.getClassCourseTeachDay().equals(other.getClassCourseTeachDay()))
            && (this.getClassCourseTeachTime() == null ? other.getClassCourseTeachTime() == null : this.getClassCourseTeachTime().equals(other.getClassCourseTeachTime()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getClassCourseTeachId() == null) ? 0 : getClassCourseTeachId().hashCode());
        result = prime * result + ((getClassCourseTeachNo() == null) ? 0 : getClassCourseTeachNo().hashCode());
        result = prime * result + ((getClassCourseTeachClassNo() == null) ? 0 : getClassCourseTeachClassNo().hashCode());
        result = prime * result + ((getClassCourseTeacherNo() == null) ? 0 : getClassCourseTeacherNo().hashCode());
        result = prime * result + ((getClassCourseTeachClassRoom() == null) ? 0 : getClassCourseTeachClassRoom().hashCode());
        result = prime * result + ((getClassCourseTeachDay() == null) ? 0 : getClassCourseTeachDay().hashCode());
        result = prime * result + ((getClassCourseTeachTime() == null) ? 0 : getClassCourseTeachTime().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", classCourseTeachId=").append(classCourseTeachId);
        sb.append(", classCourseTeachNo=").append(classCourseTeachNo);
        sb.append(", classCourseTeachClassNo=").append(classCourseTeachClassNo);
        sb.append(", classCourseTeacherNo=").append(classCourseTeacherNo);
        sb.append(", classCourseTeachClassRoom=").append(classCourseTeachClassRoom);
        sb.append(", classCourseTeachDay=").append(classCourseTeachDay);
        sb.append(", classCourseTeachTime=").append(classCourseTeachTime);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}